package com.huiyujiaoyu.powertime.ui.adapter;

import android.support.v4.app.Fragment;
import android.support.v4.app.FragmentManager;
import android.support.v4.app.FragmentPagerAdapter;

import com.huiyujiaoyu.base.BaseFragment;

import java.util.List;

/**
 * Created by yujunlong on 2016/6/27.
 */
public class AllFragmentPager2Adapter extends FragmentPagerAdapter {
    private List<BaseFragment> datas;
    public AllFragmentPager2Adapter(FragmentManager fm, List<BaseFragment> datas) {
        super(fm);
        this.datas  =datas;
    }

    @Override
    public Fragment getItem(int i) {
        return datas.get(i);
    }

    @Override
    public int getCount() {
        return datas.size();
    }
}
